<!DOCTYPE html>
<!--<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">-->
<html xmlns:th="http://www.thymeleaf.org http://www.w3.org/1999/xhtml" >
<head>
    <title>Title</title>
</head>
<head th:include="include/include"></head>
<style>
    .container{
        display:table;
        height:100%;
    }
    .MyContent{
        margin-top: 15%;
    }

    /*.row{*/
        /*display: table-cell;*/
    /*}*/
    .loginBody{
        background-color: #a6e1ec;
    }

</style>
<script>
    $(function () {
        /*设置登录框位置*/
        window.onresize=function(){
            $(".MyContent").css("margin-top","15%");
        }
    });

</script>

<body class="loginBody">
    <div class="container loginPage">
         <div class="row" id="header">
           <div class="col-md-12 col-lg-12 col-xs-12 col-sm-12 navbar-brand" style="background-color: #9acfea;">
               理赔管理系统
           </div>
       </div>
        <div class="row text-center MyContent">
            <div class="col-md-3 col-lg-3 col-xs-3 col-sm-3 col-lg-offset-5 col-md-offset-5 col-sm-offset-5 col-xs-offset-5 loginPanel">
                <div style="background-color: #9acfea;width: 250px;height:200px;margin-left: -20px;">
                    <form name="form" th:action="@{/login1}" action="/login1" method="POST">
                        <div class="form-group margin20Left margin10top" >
                            <div class="col-md-3 col-xs-3 col-sm-3 form-control form-inline margin20top" style="width: 220px;">
                                <span class="glyphicon glyphicon-user"></span>
                                <input type="text" class="" id="username" name="username" placeholder="用户名" autofocus>
                            </div>
                        </div>
                        <div class="form-group margin20Left">
                            <div class="col-md-3 col-xs-3 col-sm-3 form-control form-inline margin5top" style="width: 220px;">
                                <span class="glyphicon glyphicon-lock"></span>
                                <input type="password" class="" id="password" name="password" placeholder="密码">
                            </div>
                        </div>
                        <div class="form-group margin20Left">
                            <div class="col-md-3 col-xs-3 col-sm-3 form-control form-inline margin5top" style="width: 220px;">
                                <p th:if="${param.logout}" class="bg-warning">已成功注销</p>
                                <p style="color: red;" th:if="${param.error}" th:text="${session.SPRING_SECURITY_LAST_EXCEPTION.message}=='Bad credentials'?'账号/密码错误！':${session.SPRING_SECURITY_LAST_EXCEPTION.message}" class="bg-danger">
                            </div>

                        </div>
                        <div class="form-group margin20Left">
                            <div class="col-md-3 col-xs-3 col-sm-3  form-inline margin20top" style="width: 220px;">
                                <input type="submit" id="login" value="Login" class="btn btn-primary" />
                                <!--<button type="submit" class="btn-info btn-success width80" >登录</button>-->
                            </div>
                        </div>
                    </form>
                </div>

            </div>

        </div>
    </div>

</body>
</html>